#include <iostream>
#include "Tests.hpp"


int main()
{
    unsigned int nbFailed = 0;
    
    // Texture Manager test
    std::cout << "\e[0;30m" << TextureManagerTest::name() << "...";
    if(TextureManagerTest::test())
        std::cout << "\e[0;32msuccess" << std::endl;
    else
    {
        ++nbFailed;
        std::cout << "\e[0;31mfailed" << std::endl;
    }
 
    // LevelLoader test
    std::cout << "\e[0;30m" << LevelLoaderTest::name() << "...";
    if(LevelLoaderTest::test())
        std::cout << "\e[0;32msuccess" << std::endl;
    else
    {
        ++nbFailed;
        std::cout << "\e[0;31mfailed" << std::endl;
    }
       
    if(!nbFailed)
        std::cout << std::endl << "\e[0;32mRESULT: All tests have been successful." << std::endl;
    else
        std::cout << std::endl << "\e[0;31mRESULT: " << nbFailed << " tests have failed." << std::endl;
    return 0;
}
